import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:aweb5/util/NaviUtil.dart';
class InputPage extends StatefulWidget {
  @override
  _InputPageState createState() => _InputPageState();
}

class _InputPageState extends State<InputPage> {
  TextEditingController controller = TextEditingController();
  @override
  Widget build(BuildContext context) {
    return Scaffold(

        body:

        SafeArea(child: Column(

          children: <Widget>[

            Container(
              margin: EdgeInsets.all(10),
              width: ScreenUtil().setWidth(414),
              height: ScreenUtil().setHeight(414),
              decoration: BoxDecoration(color: Colors.white,borderRadius: BorderRadius.circular(10),border: Border.all(color: Colors.grey)),
              child: TextField(
                controller: controller,
                keyboardType: TextInputType.multiline,
                maxLines: null,
                decoration: InputDecoration(
                  hintText: "请输入",
                  hintStyle: TextStyle(color: Colors.grey),
                  border: InputBorder.none
                ),

              ),
            ),

            FlatButton(onPressed: (){
//              NaviUtil.pop(Navigator.of(context).pop((){}));
//              Navigator.of(context).pop();
              Navigator.of(context).pop(controller.text);

//              Navigator.of(context).popAndPushNamed(routeName)
              
            }, child: Text("保存",style: TextStyle(color:Colors.white),),color: Colors.blue,)
          ],

        ))
        ,

    );
  }



}
